﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Atendimento.Master" AutoEventWireup="true" CodeBehind="FormPaciente.aspx.cs" Inherits="PROAD.atendimento.Forms.FormPaciente" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

<asp:Content ID="Content1" ContentPlaceHolderID="IncludeHead" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="IncludeTitulo" runat="server">
    <h1>Fomulário para cadastro de usuários</h1>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="IncludeCaminho" runat="server">
    <h1><a href="/atendimento/Consulta/ConsultaPacientes.aspx">Lista de usuários</a></h1>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="IncludeConteudo" runat="server">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
        <br />
    <table width="100%" cellpadding="3" cellspacing="0" border="0">
        <tr>
            <td colspan="3" >Nome Completo</td>
           
            <td>Cartão SUS</td>
            <td>Sexo</td>
        </tr>
          <tr>
            <td colspan="3" >
              <asp:TextBox ID="txtNome" runat="server" Width="536px"></asp:TextBox></td>
            <td>
              <asp:TextBox ID="txtCpf" runat="server" Width="110px" MaxLength="14"></asp:TextBox>
             
              </td>
            <td>
              <asp:DropDownList ID="ddlSexo" runat="server" Width="169px">
                <asp:ListItem Value="0" Text="Selecione..."></asp:ListItem>
                <asp:ListItem Value="1" Text="Masculino"></asp:ListItem>
                <asp:ListItem Value="2" Text="Feminino"></asp:ListItem>
              </asp:DropDownList></td>
        </tr>
        <tr>
            <td colspan="5">
                Endereço
            </td>
        </tr>
         <tr>
            <td colspan="5">
                <asp:TextBox ID="txtEndereco" runat="server" Width="750px"></asp:TextBox>
            </td>
        </tr>
          <tr>
            <td>UF</td>
            <td colspan="2">Município</td>
            
            <td>CEP</td>
            <td>Data de Nascimento</td>
        </tr>
          <tr>
            <td><asp:DropDownList ID="ddlUf" runat="server" DataTextField="NO_UF" 
                    DataValueField="CO_UF" onselectedindexchanged="ddlUf_SelectedIndexChanged" AutoPostBack="true" >
              </asp:DropDownList></td>
            <td colspan="2"> <asp:DropDownList ID="ddlMunicipio" runat="server" DataValueField="CO_CIDADE" DataTextField="NO_CIDADE">
              </asp:DropDownList></td>
            <td>
              <asp:TextBox ID="txtCep" runat="server" Width="75px"></asp:TextBox>
              <asp:MaskedEditExtender ID="MaskCep" runat="server" MaskType="Number" TargetControlID="txtCep"
                            Mask="99,999-999" ClearMaskOnLostFocus="false">
                        </asp:MaskedEditExtender>
              </td>
            <td>
              <asp:TextBox ID="txtDataNasc" runat="server" Width="70px"></asp:TextBox>
              <asp:MaskedEditExtender ID="MaskDtNasc" runat="server" MaskType="Number" TargetControlID="txtDataNasc"
                            Mask="99/99/9999" ClearMaskOnLostFocus="false">
                        </asp:MaskedEditExtender>
              </td>
        </tr>
        <tr>
            <td colspan="3">
              US  
            </td>
            <td colspan="2">
                ES
            </td>
        </tr>
        <tr>
            <td colspan="3">
             <asp:DropDownList ID="ddlUS" runat="server" Width="115px" 
                                DataValueField="CO_US" DataTextField="NO_US" AutoPostBack="true" 
                                onselectedindexchanged="ddlUS_SelectedIndexChanged">
                            </asp:DropDownList>  
            </td>
            <td colspan="2">
               <asp:DropDownList ID="ddlEs" runat="server" Width="115px" DataValueField="CO_ES" DataTextField="NO_ES">
                            </asp:DropDownList>
                            <asp:Label ID="lblMsnErroEquipe" runat="server" ForeColor="Red"></asp:Label>
            </td>
        </tr>
         <tr>
            <td colspan="3">Telefone</td>
           <%-- <td>Microárea do ACS</td>--%>
            <td colspan="2">Situação</td>
        </tr>
         <tr>
            <td colspan="3">
              <asp:TextBox ID="txtTelefone" runat="server"></asp:TextBox></td>
          <%--  <td><asp:DropDownList ID="ddlMicroArea" runat="server" Width="169px">
              </asp:DropDownList></td>--%>
            <td colspan="2"><asp:DropDownList ID="ddlSituacao" runat="server">
                <asp:ListItem Value="0" Text="Inativo"></asp:ListItem>
                <asp:ListItem Value="1" Text="Ativo"></asp:ListItem>
              </asp:DropDownList></td>
        </tr>
         <tr>
            <td colspan="5">&nbsp;</td>
         </tr>
          <tr>
            <td colspan="5">
            <div style="margin-left:780px">
                       <asp:Button ID="btnCancelar" runat="server" Text="Cancelar" 
                           onclick="btnCancelar_Click" />&nbsp;&nbsp;
                       <asp:Button ID="btnSalvar" runat="server" Text="Salvar" 
                           onclick="btnSalvar_Click" />
                       <asp:Button ID="btnEditar" runat="server" Text="Salvar" 
                        Visible="false" onclick="btnEditar_Click" />
                       </div>
            </td>
         </tr>
    </table>
      <!-- Área de Validação abaixo -->
             <div style="display:none;">
                 <asp:HyperLink ID="linkMsn" runat="server">HyperLink</asp:HyperLink>
             </div>
             <asp:ModalPopupExtender ID="ModalPopupMsn" runat="server" 
                 BackgroundCssClass="modalBackground" CancelControlID="btnCancelarMsn" 
                 PopupControlID="PainelMsn" TargetControlID="linkMsn">
             </asp:ModalPopupExtender>
             <asp:Panel ID="PainelMsn" runat="server" CssClass="modalPopup" 
                 Style="display:none" Width="350px">
                 <asp:Panel ID="PainelCabecalho" runat="server" 
                     Style="border-bottom:solid 1px Gray;height:25px;">
                     <div>
                         <h1 
                             style="line-height: 25px; text-align: center; margin: 0px 0px 0px 0px; vertical-align: bottom;
                            padding: 0px 0px 0px 0px; font-size: 14px; font-family: Verdana; background-color: #A4CFA2;">
                             <asp:Label ID="txtTituloMsn" runat="server"></asp:Label>
                         </h1>
                     </div>
                 </asp:Panel>
                 <div>
                     <br />
                     <h2 style="margin: 0px 0px 0px 0px; font-family: Verdana; font-size: 11px; font-weight: normal;
                        line-height: 25px; width: 100%; text-align: center;">
                         <asp:Label ID="txtTextoMsn" runat="server"></asp:Label>
                     </h2>
                     <br />
                     <table width="100%">
                         <tr>
                             <td align="center">
                                   
                                        <asp:Button ID="btnCancelarMsn" runat="server" Text="OK" />
                                  
                                        <%--<asp:Button ID="btnRedirecionar" runat="server" Text="OK" OnClick="btnRedirecionar_Click" />--%>
                             </td>
                         </tr>
                     </table>
                 </div>
             </asp:Panel>
             <!-- Final Área de Validação -->

        </ContentTemplate>
        </asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="IncludeRodape" runat="server">
</asp:Content>
